const state = {
    // 文件树
    fileList: [],
    // 文件夹树
    folderList: [],

    // 文件批量上传个数限制
    fileUploadMax: 999,

    // 正在上传的文件列表
    fileListActive: [],
    // 特殊字符数组
    specialCharArray: ['\\', '/', ':', '*', '?', '<', '>', '|'],
    // 搜索文件结果
    fileListSearch: [],

    // 截图图片地址
    screenImgSrc: '',

    // 当前文件夹id
    currentDirectoryId: '',
    // 所有选中的文件
    allSelectedFileList: [],
    // 所有选中的文件
    allSelectedFolderList: [],
    // 签章和手印的数组
    sealAndFingerprintList: [],
    // 多页PDF选择是否展示
    previewStatus: false,
    // 是否显示web截图效果
    shadowGrayShow: false,
    // 识别状态符
    status:null
}

const getters = {}

const actions = {}

const mutations = {
    setFileList(state, fileList) {
        state.fileList = fileList;
    },
    setFolderList(state, folderList) {
        state.folderList = folderList;
    },
    setFileListActive(state, fileListActive) {
        state.fileListActive = fileListActive;
    },
    setFileListSearch(state, fileListSearch) {
        state.fileListSearch = fileListSearch;
    },
    setScreenImgSrc(state, screenImgSrc) {
        state.screenImgSrc = screenImgSrc;
    },
    setDirectoryId(state, currentDirectoryId) {
        state.currentDirectoryId = currentDirectoryId;
    },
    setAllSelectedFileList(state, allSelectedFileList) {
        state.allSelectedFileList = allSelectedFileList;
    },
    setAllSelectedFolderList(state, allSelectedFolderList) {
        state.allSelectedFolderList = allSelectedFolderList;
    },
    setSealAndFingerprintList(state, sealAndFingerprintList) {
        state.sealAndFingerprintList = sealAndFingerprintList;
    },
    setPreviewStatus(state, previewStatus) {
        state.previewStatus = previewStatus;
    },
    setShadowGrayShow(state, shadowGrayShow) {
        state.shadowGrayShow = shadowGrayShow;
    },
    setStatus(state, status) {
        state.status = status;
    },
}

export default {
    namespaced: true,
    state,
    getters,
    actions,
    mutations
}
